<template>
    <div class="doc-content-wrapper">
        <div class="doc-content-container">
            <div class="doc-content">
                <h2 class="mb-5 flex items-center">数组合并成字符串</h2>
                <Codemirror :code="joinCode1" name="join数组合并成字符串" class="mb-10" />
            </div>
        </div>
    </div>
</template>

<script lang="ts">
import { defineComponent, ref } from 'vue'

export default defineComponent({
    setup () {
        const joinCode1 = ref(`var a = ['I', 'am', 'a', 'girl', '英文名', '是', 'gaby']
var arr = a.join(',')

console.log(arr)`)

        return {
            joinCode1
        }
    }
})
</script>

<style scoped>

</style>